package cn.momoky.ccool.utils;


import org.springframework.stereotype.Component;

@Component
public class FileTool {

    public String getParentPath(String path) {
        return path.substring(0, path.lastIndexOf('/'));
    }

    private String getNodeName(String path) {
        return path.substring(path.lastIndexOf("/"));
    }

    private String getRootName(String path) {
        return path.substring(0, path.indexOf('/'));
    }
}
